package cn.ronghuanet.permission.service.impl;

import cn.ronghuanet.basic.service.impl.BaseServiceImpl;
import cn.ronghuanet.permission.domain.Permission;
import cn.ronghuanet.permission.mapper.PermissionMapper;
import cn.ronghuanet.permission.service.IPermissionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class PermissionServiceImpl extends BaseServiceImpl<Permission> implements IPermissionService {

    @Autowired
    private PermissionMapper permissionMapper;


    @Override
    public List<Permission> tree() {
        return permissionMapper.tree();
    }

    @Override
    public List<String> getPermissionSnsByLoginUserId(Long loginUserId) {
        return permissionMapper.loadPermissionSnsByLoginUserId(loginUserId);
    }
}
